package com.yunhe.policyfulfillment.policyful.service.impl;

import com.yunhe.policyfulfillment.policyful.domain.PolicyApprovalTimeLimit;
import com.yunhe.policyfulfillment.policyful.repository.PolicyApprovalTimeLimitMapper;
import com.yunhe.policyfulfillment.policyful.service.PolicyApprovalTimeLimitService;
import lombok.RequiredArgsConstructor;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
@RequiredArgsConstructor
public class PolicyApprovalTimeLimitImpl implements PolicyApprovalTimeLimitService {
    private final PolicyApprovalTimeLimitMapper mapper;

    @Override
    public List<PolicyApprovalTimeLimit> findAll() {
        return mapper.selectAll();
    }

    @Override
    public int updateById(PolicyApprovalTimeLimit limit) {
        return mapper.updateByPrimaryKeySelective(limit);
    }
}
